import type { AxiosRequestConfig, AxiosResponse } from 'axios'
export interface IRequestInterceptors {
  /**自定义拦截接口 */
  requestInterceptor?: (config: AxiosRequestConfig) => AxiosRequestConfig
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
  requestInterceptorCatch?: (config: any) => any
  responseInterceptor?: (config: AxiosResponse) => AxiosResponse
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
  responseInterceptorCatch?: (config: any) => any
}

export interface ISelfRequestConfig extends AxiosRequestConfig {
  /**继承AxiosRequestConfig的同时，扩展IRequestInterceptors */
  interceptors?: IRequestInterceptors
  showLoading?: boolean
}
